home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / hf^k-1.dms / in.adf / oemsetup.inf < prev    next >
Encoding:
Text File  |  1996-01-19  |  11.7 KB  |  375 lines

  1. ; OEM Setup script 10/96 Dietmar Eilert $VER: 1.1 (29.10.1996)
  2.  
  3. $$$(welcome)
  4. ;====================== SECTION 1 ==============================================
  5.  
  6. (if (= @language "deutsch")
  7.  
  8.     (set #golded_info
  9.  
  10.         (cat "\n"
  11.  
  12.             "                                              \n"
  13.             "Dieses Compiler-Paket enthält Release 4 des   \n"
  14.             "Editors GoldED.                               \n"
  15.             "                                              \n"
  16.             "GoldED/OEM - Programmer's Editor              \n"
  17.             "                                              \n"
  18.             "Lizenzierter Vertrieb durch:                  \n"
  19.             "                                              \n"
  20.             "HAAGE & PARTNER Computer GmbH                 \n"
  21.         )
  22.     )
  23.  
  24.     (set #golded_info
  25.  
  26.         (cat "\n"
  27.  
  28.             "                                              \n"
  29.             "This compiler package containes release 4 of  \n"
  30.             "the editor GoldED.                            \n"
  31.             "                                              \n"
  32.             "GoldED/OEM - Programmer's Editor              \n"
  33.             "                                              \n"
  34.             "Licenced for distribution by:                 \n"
  35.             "                                              \n"
  36.             "HAAGE & PARTNER Computer GmbH                 \n"
  37.         )
  38.     )
  39. )
  40.  
  41. (message #golded_info)
  42.  
  43. $$$(complete 99)
  44. ;====================== SECTION 2 ==============================================
  45.  
  46. (if (= @language "deutsch")
  47.  
  48.     (
  49.         (set #golded_ask_install (cat "\n"
  50.  
  51.             "Dieses Compiler-Paket enthält Release 4 des   \n"
  52.             "Editors GoldED.                               \n"
  53.             "                                              \n"
  54.             "Soll dieser Editor installiert werden ?       \n"
  55.         ))
  56.  
  57.         (set #golded_ask_install_help
  58.  
  59.             (cat "\n"
  60.  
  61.                  " StormC wird zur Zeit mit zwei Editoren ausge- \n"
  62.                  " liefert: StormED und GoldED. Die Installation \n"
  63.                  " von GoldED ist optional möglich.              \n"
  64.             )
  65.         )
  66.  
  67.         (set #golded_ask_install_yes "Installieren")
  68.  
  69.         (set #golded_ask_install_no  "Nein")
  70.  
  71.         (set #golded_insert_disk6
  72.  
  73.             (cat "\n\n\nBitte legen Sie nun die Diskette 6 in ein beliebiges Laufwerk ein !")
  74.         )
  75.  
  76.         (set #golded_insert_disk7
  77.  
  78.             (cat "\n\n\nBitte legen Sie nun die Diskette 7 in ein beliebiges Laufwerk ein !")
  79.         )
  80.  
  81.         (set #golded_info_error        "\nWarnung: GoldED-Installation unvollständig !"      )
  82.         (set #golded_info_incomplete   "\nWarnung: GoldED-Installation unvollständig !"      )
  83.         (set #golded_info_ok           "\nGoldED wurde erfolgreich installiert."             )
  84.         (set #golded_info_noscript     "\nGoldED-Installation nicht möglich: Script fehlt"   )
  85.         (set #golded_info_noinstaller  "\nGoldED-Installation nicht möglich: Installer fehlt")
  86.  
  87.         (set #golded_ask_extras "\nGoldED-Extras installieren\n")
  88.  
  89.         (set #golded_ask_extras_help (cat "\n"
  90.  
  91.             " GoldED wird mit einer speziellen Erweiterung   \n"
  92.             " für StormC ausgeliefert. Sie können diese Er-  \n"
  93.             " weiterung später direkt von der Extras-Disk    \n"
  94.             " installieren. Auf Wunsch kann die Installation \n"
  95.             " dieser Komponenten auch jetzt erfolgen.        \n"
  96.         ))
  97.  
  98.         (set #golded_ask_extras_envSTM "StormC-Umgebung")
  99.     )
  100.  
  101.     ; English strings
  102.  
  103.     (
  104.         (set #golded_ask_install (cat "\n"
  105.  
  106.             "This compiler package containes release 4 of  \n"
  107.             "the editor GoldED.                            \n"
  108.             "                                              \n"
  109.             "Do you want to have this editor installed ?   \n"
  110.         ))
  111.  
  112.         (set #golded_ask_install_help
  113.  
  114.             (cat "\n"
  115.  
  116.                  " StormC currently is shipped with two editors: \n"
  117.                  " GoldED and StormED. The installation of GoldED\n"
  118.                  " is optional.                                  \n"
  119.             )
  120.         )
  121.  
  122.         (set #golded_ask_install_yes "Install")
  123.  
  124.         (set #golded_ask_install_no  "No")
  125.  
  126.         (set #golded_insert_disk6
  127.  
  128.             (cat "\n\n\nPlease insert disk 6 into any disk drive !")
  129.         )
  130.  
  131.         (set #golded_insert_disk7
  132.  
  133.             (cat "\n\n\nPlease insert disk 7 into any disk drive !")
  134.         )
  135.  
  136.         (set #golded_info_error       "\nWarning: GoldED installation incomplete !"             )
  137.         (set #golded_info_incomplete  "\nWarning: GoldED installation incomplete !"             )
  138.         (set #golded_info_ok          "\nGoldED has been installed successfully."               )
  139.         (set #golded_info_noscript    "\nGoldED installation not available: script not found"   )
  140.         (set #golded_info_noinstaller "\nGoldED installation not available: installer not found")
  141.  
  142.         (set #golded_ask_extras "\nInstall GoldED Extras\n")
  143.  
  144.         (set #golded_ask_extras_help (cat "\n"
  145.  
  146.             " GoldED is shipped with a specific extended    \n"
  147.             " configuration for StormC. You can install it  \n"
  148.             " directly from the extras disk later or have it\n"
  149.             " installed right now.                          \n"
  150.         ))
  151.  
  152.         (set #golded_ask_extras_envSTM "StormC environment")
  153.     )
  154. )
  155.  
  156. (set golded_install
  157.  
  158.     (askbool
  159.  
  160.         (prompt #golded_ask_install)
  161.         (help   #golded_ask_install_help)
  162.  
  163.         (default 0)
  164.  
  165.         (choices
  166.  
  167.             #golded_ask_install_yes
  168.             #golded_ask_install_no
  169.         )
  170.     )
  171. )
  172.  
  173. (if (= golded_install 1)
  174.  
  175.     (
  176.         (working "GoldED Installation ...")
  177.  
  178.         ; look for GoldED files (consider that we may run from a CD ROM)
  179.  
  180.         (if (exists "install.run" (quiet))
  181.  
  182.             (set golded_disk (expandpath ""))
  183.  
  184.             (
  185.                 (if (exists "/disk6" (quiet))
  186.  
  187.                     (set golded_disk (expandpath "/disk6"))
  188.  
  189.                     (
  190.                         (if (exists "/StormC_Disk6" (quiet))
  191.  
  192.                             (set golded_disk (expandpath "/StormC_Disk6"))
  193.  
  194.                             (
  195.                                 (set golded_disk "StormC_Disk6:")
  196.  
  197.                                 (askdisk
  198.  
  199.                                     (prompt #golded_insert_disk6)
  200.                                     (help   #askdir-help)
  201.                                     (dest   "StormC_Disk6")
  202.                                 )
  203.                             )
  204.                         )
  205.                     )
  206.                 )
  207.             )
  208.         )
  209.  
  210.         (set golded_script (tackon golded_disk "Install"))
  211.  
  212.         (if (exists golded_script)
  213.  
  214.             (
  215.                 ; look for installer (ram-resident copy usually created by OEM Setup)
  216.  
  217.                 (if (exists "welcome:installer" (noreq))
  218.  
  219.                     (set golded_installer "Welcome:installer")
  220.  
  221.                     (if (exists "t:installer" (noreq))
  222.  
  223.                         (set golded_installer "t:installer")
  224.  
  225.                         (if (exists "ram:installer" (noreq))
  226.  
  227.                             (set golded_installer "ram:installer")
  228.  
  229.                             (
  230.                                 (message #golded_info_noinstaller)
  231.  
  232.                                 (set golded_installer "installer")
  233.                             )
  234.                         )
  235.                     )
  236.                 )
  237.  
  238.                 ; create command string for installer
  239.  
  240.                 (set golded_cmd
  241.  
  242.                     (cat
  243.  
  244.                         golded_installer
  245.  
  246.                         " SCRIPT install APPNAME GoldED DEFUSER average LANGUAGE "
  247.  
  248.                         @language
  249.                     )
  250.                 )
  251.  
  252.                 ; launch installer (CD to directory, run script, then restore current path)
  253.  
  254.                 (set golded_old_path @execute-dir)
  255.  
  256.                 (set @execute-dir golded_disk)
  257.  
  258.                 (run golded_cmd)
  259.  
  260.                 (set @execute-dir golded_old_path)
  261.  
  262.                 ; stop Describe presentation
  263.  
  264.                 (run (tackon golded_disk "bin/sync COMMAND=QUIT"))
  265.  
  266.                 ; check return code of GoldED installation; possible values: INCOMPLETE, ERROR, REMOVED, OK
  267.  
  268.                 (if (exists "env:GOLDEDINSTALL" (noreq))
  269.  
  270.                     ; (getenv) may not be used without checking if var exists (installer bug)
  271.  
  272.                     (set golded_install_code (getenv "GOLDEDINSTALL"))
  273.  
  274.                     (set golded_install_code "ERROR")
  275.                 )
  276.  
  277.                 (if (= golded_install_code "ERROR")
  278.  
  279.                     (message #golded_info_error)
  280.                 )
  281.  
  282.                 (if (= golded_install_code "INCOMPLETE")
  283.  
  284.                     (message #golded_info_incomplete)
  285.                 )
  286.  
  287.                 (if (= golded_install_code "OK")
  288.  
  289.                     (
  290.                         ; process next disk (extras)
  291.  
  292.                         (set golded_install_extras (askoptions
  293.  
  294.                             (prompt #golded_ask_extras)
  295.                             (help   #golded_ask_extras_help)
  296.  
  297.                             (default 1)
  298.  
  299.                             (choices
  300.  
  301.                                 #golded_ask_extras_envSTM
  302.                             )
  303.                         ))
  304.  
  305.                         (if (= golded_install_extras 1)
  306.  
  307.                             (
  308.                                 (working "Extras Installation ...")
  309.  
  310.                                 (if (exists "/disk7" (quiet))
  311.  
  312.                                     (set golded_extras (expandpath "/disk7"))
  313.  
  314.                                     (
  315.                                         (if (exists "/StormC_Disk7" (quiet))
  316.  
  317.                                             (set golded_extras (expandpath "/StormC_Disk7"))
  318.  
  319.                                             (
  320.                                                 (set golded_extras "StormC_Disk7:")
  321.  
  322.                                                 (askdisk
  323.  
  324.                                                     (prompt #golded_insert_disk7)
  325.                                                     (help   #askdir-help)
  326.                                                     (dest   "StormC_Disk7")
  327.                                                 )
  328.                                             )
  329.                                         )
  330.                                     )
  331.                                 )
  332.  
  333.                                 (set golded_script (tackon golded_extras "envSTM20/Install"))
  334.  
  335.                                 (if (exists golded_script)
  336.  
  337.                                     (
  338.                                         ; create command string for installer
  339.  
  340.                                         (set golded_cmd
  341.  
  342.                                             (cat
  343.  
  344.                                                 golded_installer
  345.  
  346.                                                 " SCRIPT Install APPNAME Extras DEFUSER average LANGUAGE "
  347.  
  348.                                                 @language
  349.                                             )
  350.                                         )
  351.  
  352.                                         ; launch installer (CD to directory, run script, then restore current path)
  353.  
  354.                                         (set golded_old_path @execute-dir)
  355.  
  356.                                         (set @execute-dir (tackon golded_extras "envSTM20"))
  357.  
  358.                                         (run golded_cmd)
  359.  
  360.                                         (set @execute-dir golded_old_path)
  361.                                     )
  362.                                 )
  363.                             )
  364.                         )
  365.                     )
  366.                 )
  367.  
  368.                 (message #golded_info_ok)
  369.             )
  370.  
  371.             (message #golded_info_noscript)
  372.         )
  373.     )
  374. )
  375.